package com.pubinfo.passbook.common.entity;

import com.alibaba.fastjson.JSONObject;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import java.io.Serializable;
import java.math.BigDecimal;
import java.time.LocalDateTime;
import java.util.ArrayList;
import java.util.Date;
import java.util.List;

import com.baomidou.mybatisplus.extension.handlers.FastjsonTypeHandler;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.pubinfo.passbook.common.handler.TSourceBankReconciliationStatementDetailsTypeHandler;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Getter;
import lombok.Setter;
import lombok.experimental.Accessors;

/**
 * <p>
 * 
 * </p>
 *
 * @author xuhong
 * @since 2022-05-25
 */
@Getter
@Setter
@Accessors(chain = true)
@TableName(value = "t_source_bank_reconciliation_statement",autoResultMap = true)
@ApiModel(value = "TSourceBankReconciliationStatement对象", description = "")
public class TSourceBankReconciliationStatement implements Serializable {

    private static final long serialVersionUID = 1L;

    @TableId(type = IdType.ASSIGN_ID, value = "id")
    private String id;

    @ApiModelProperty("签发机构")
    @TableField("identification_code_of_issuer")
    private String identificationCodeOfIssuer;

    @ApiModelProperty("营业网点编号")
    @TableField("number_of_bank_branch")
    private String numberOfBankBranch;

    @ApiModelProperty("币种")
    @TableField("currency")
    private String currency;

    @ApiModelProperty("客户结算账号")
    @TableField("customer_settlement_bank_account")
    private String customerSettlementBankAccount;

    @ApiModelProperty("客户账户名称")
    @TableField("name_of_customer_account")
    private String nameOfCustomerAccount;

    @ApiModelProperty("银行客户编码")
    @TableField("code_of_bank_customer")
    private String codeOfBankCustomer;

    @ApiModelProperty("银行对账单年份")
    @TableField("year_of_bank_reconciliation_statement")
    private String yearOfBankReconciliationStatement;

    @ApiModelProperty("银行对账单月份")
    @TableField("month_of_bank_reconciliation_statement")
    private String monthOfBankReconciliationStatement;

    @ApiModelProperty("打印次数")
    @TableField("print_times")
    private byte[] printTimes;

    @ApiModelProperty("打印日期")
    @TableField("print_date")
    @JsonFormat(pattern = "yyyy-MM-dd", timezone = "GMT+8")
    private Date printDate;

    @ApiModelProperty("对账明细信息")
    @TableField(value = "information_of_reconcile_details_tuple",typeHandler = TSourceBankReconciliationStatementDetailsTypeHandler.class)
    private List<TSourceBankReconciliationStatementDetails> informationOfReconcileDetailsTuple =new ArrayList<>();

    @ApiModelProperty("对账周期末账户余额（额度）")
    @TableField("account_balance_at_the_end_of_reconciliation_cycle_amount")
    private BigDecimal accountBalanceAtTheEndOfReconciliationCycleAmount;

    @ApiModelProperty("对账周期末保留余额")
    @TableField("reserve_balance_at_the_end_of_reconciliation_cycle")
    private BigDecimal reserveBalanceAtTheEndOfReconciliationCycle;

    @ApiModelProperty("对账周期末冻结余额")
    @TableField("frozen_balance_at_the_end_of_reconciliation_cycle")
    private BigDecimal frozenBalanceAtTheEndOfReconciliationCycle;

    @ApiModelProperty("对账周期末透支余额")
    @TableField("overdraft_balance_at_end_of_reconciliation_cycle")
    private BigDecimal overdraftBalanceAtEndOfReconciliationCycle;

    @ApiModelProperty("对账周期末可用余额（额度）")
    @TableField("available_balance_at_the_end_of_reconciliation_cycle_amount")
    private BigDecimal availableBalanceAtTheEndOfReconciliationCycleAmount;

    @TableField(typeHandler = FastjsonTypeHandler.class)
    private JSONObject dataJson;


}
